/********************************************
 * 功能说明: 
 * 模块名称: 
 * 系统名称: 
 * 软件版权: Frank
 * 系统版本: 1.0.0
 * 开发人员: leebean
 * 开发时间: 2020/1/2 11:24
 * 审核人员: 
 * 相关文档: 
 * 修改记录: 修改日期 修改人员 修改说明
 *********************************************/
package com.spring.arch.message.client;

import com.spring.arch.common.dto.result.ResultDTO;
import com.spring.arch.common.dto.result.ResultDTO;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestParam;

/**
 * 短信客户端
 *
 * @author leebean
 * @version 1.0.0
 * @since 2020/1/2 11:24
 */
@FeignClient(value = "${service.message}", path = "/message/msg", fallback = MessageClientHystrix.class)
public interface MessageClient {

    @PostMapping(value = "/workorder/receive")
    ResultDTO receiveWorkorder(@RequestParam(value = "orderType") String orderType,
                               @RequestParam(value = "phone") String phone,
                               @RequestParam(value = "orderCode") String orderCode);

    @PostMapping(value = "/workorder/timeout")
    ResultDTO timeoutWorkorder(@RequestParam(value = "orderType") String orderType,
                               @RequestParam(value = "phone") String phone,
                               @RequestParam(value = "orderCode") String orderCode,
                               @RequestParam(value = "orderProcess") String orderProcess);

    @PostMapping(value = "/workorder/follow")
    ResultDTO followWorkorder(@RequestParam(value = "orderType") String orderType,
                              @RequestParam(value = "phone") String phone,
                              @RequestParam(value = "orderCode") String orderCode);
}
